﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;
using CommerceOne.Widgets.Breadcrumb;
using CommerceOne.Widgets.CheckoutStep;

namespace CommerceOne.Models
{
    public class LoginViewModel : ViewModelBase
    {
        public List<String> Errors { get; set; }
        public BreadcrumbViewModel Breadcrumb { get; set; }
        public CheckoutStepViewModel Step { get; set; }

        [Required]
        public string User { get; set; }
        public string Password { get; set; }
        public Boolean RememberMe { get; set; }

        public Boolean IsValid { get { return this.Errors.Count == 0; } }

        public LoginViewModel()
        {
            this.Errors = new List<string>();
        }
    }
}